namespace Cos.Core.NHibernate
{
    public class VideoTagDataModel
    {
        #region Constructors and Destructors

        public VideoTagDataModel() {}

        #endregion

        #region Properties

        public virtual string CultureCode { get; set; }
        
        // public virtual TagDataModel TagDataModel { get; set; }

        public virtual string TagName { get; set; }

        //public virtual VideoDataModel Video { get; set; }

        public virtual int VideoId { get; set; }

        #endregion

        #region Object Overrides

        public override bool Equals(object obj)
        {
            if (obj == null)
            {
                return false;
            }

            var model = obj as VideoTagDataModel;

            return model != null && this.VideoId == model.VideoId && this.TagName == model.TagName &&
                   this.CultureCode == model.CultureCode;
        }

        public override int GetHashCode()
        {
            return this.VideoId.GetHashCode() 
                ^ this.TagName.GetHashCode()
                ^ this.CultureCode.GetHashCode();
        }

        #endregion
    }
}